<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Insert title here</title>
<link rel='stylesheet' type='text/css' href="/${initParam.context_root}/css/fullcalendar/fullcalendar.css" />
<link rel='stylesheet' type='text/css' href="/${initParam.context_root}/css/fullcalendar/fullcalendar.print.css" media='print' />
<script type='text/javascript' src="/${initParam.context_root}/jquery-1.7.2.min.js"></script>
<script type='text/javascript' src="/${initParam.context_root}/jquery-ui-1.8.21.custom.min.js"></script>
<script type='text/javascript' src="/${initParam.context_root}/fullcalendar.min.js"></script>
<script type='text/javascript'>
$(document).ready(function() {
	
	var date = new Date();
	var d = date.getDate();
	var m = date.getMonth();
	var y = date.getFullYear();
	
	$('#calendar').fullCalendar({
		header: {
			left: 'prev,next today',
			center: 'title',
			right: 'month,basicWeek,basicDay'
		},
		events: [
			{
				title: "노트북",
				start: new Date(y, m, 1),
				end: new Date(y, m, 4),
				url:'/${initParam.context_root}/searchProductByProductName.do?productName=노트북'
			},
			
			{
				title: "케이준 치킨 샐러드",
				start: new Date(y, m, 2)	,
				end: new Date(y, m, 20),
				url:'/${initParam.context_root}/searchProductByProductName.do?productName=케이준 치킨 샐러드'
			},
			
			{
				title: "스마트폰",
				start: new Date(y, m, 5),
				end: new Date(y, m, 11),
				url:'/${initParam.context_root}/searchProductByProductName.do?productName=스마트폰'
			},
			
			{
				title: "핸드백",
				start: new Date(y, m, 4),
				end: new Date(y, m, 6),
				url:'/${initParam.context_root}/searchProductByProductName.do?productName=핸드백'
			},
		]
	});
	
});
</script>

<style type='text/css'>
body {
	margin-top: 40px;
	text-align: center;
	font-size: 14px;
	font-family: "Lucida Grande",Helvetica,Arial,Verdana,sans-serif;
	}
#calendar {
	width: 900px;
	margin: 0 auto;
	}
</style>
</head>

<body>
	<div id='loading' style='display:none'>loading...</div>
	<div id='calendar'></div>
</body>
</html>
